module.exports = (mysql, Sequelize) => {
	let login = mysql.define('login', {
		name: {
			type: Sequelize.STRING(40)
		},
		passwd: {
			type: Sequelize.STRING(40)
		},
		nickName: {
			type: Sequelize.STRING(40)
    },
    isEnable: {
      type: Sequelize.BOOLEAN,
      comment: '是否有效',
      defaultValue: true
    }
	}, {
    indexes: [{
      unique: true,
      fields: ['name']
    }]				
  })

	return login;
};